const routerView = {
  render: (h) => h("router-view"),
};
export const routerList = [
  {
    path: "/home",
    name: "home",
    component: () => import("@/views/Home.vue"),
    meta: {
      title: "首页",
    },
  },
  // 旅游景点管理
  {
    path: "travel-admin",
    name: "travel-admin",
    component: routerView,
    redirect: "/travel-list",
    meta: {
      title: "旅游管理",
    },
    children: [
      {
        path: "/travel-list",
        name: "travel-list",
        component: () => import("../views/travel/travel-list.vue"),
        meta: {
          title: "旅游列表",
        },
      },
    ],
  },
  // 美食信息
  {
    path: "foods-admin",
    name: "foods-admin",
    component: routerView,
    redirect: "/foods-list",
    meta: {
      title: "美食管理",
    },
    children: [
      {
        path: "/foods-list",
        name: "foods-list",
        component: () => import("../views/foods-admin/foods-list.vue"),
        meta: {
          title: "美食列表",
        },
      },
    ],
  },
  // 文章游记
  {
    // 文章游记,
    path: "travelNotes",
    name: "travelNotes",
    component: routerView,
    redirect: "/noterList",
    meta: {
      title: "文章游记",
    },
    children: [
      {
        path: "/noterList",
        name: "noterList",
        component: () => import("../views/travelNotes/noterList.vue"),
        meta: {
          title: "游记列表",
        },
      },
    ],
  },
  // 新闻资讯
  {
    path: "news-info",
    name: "news-info",
    component: routerView,
    redirect: "/news-list",
    meta: {
      title: "新闻资讯",
    },
    children: [
      {
        path: "/news-list",
        name: "news-list",
        component: () => import("../views/news-info/news-list.vue"),
        meta: {
          title: "新闻列表",
        },
      },
    ],
  },
  // 旅行推荐
  {
    // 文章游记,
    path: "/recommend",
    name: "recommend",
    component: routerView,
    redirect: "/recommend-list",
    meta: {
      title: "推荐管理",
    },
    children: [
      {
        path: "/recommend-list",
        name: "recommend-list",
        component: () => import("../views/recommend/recommend-list.vue"),
        meta: {
          title: "管理列表",
        },
      },
    ],
  },
  // 用户管理
  {
    path: "/user",
    name: "user",
    component: routerView,
    redirect: "/user-list",
    meta: {
      title: "用户管理",
    },
    children: [
      {
        path: "/user-list",
        name: "user-list",
        component: () => import("../views/user/user-list.vue"),
        meta: {
          title: "用户列表",
        },
      },
      {
        path: "/order-list",
        name: "order-list",
        component: () => import("../views/user/order-list.vue"),
        meta: {
          title: "用户订单",
        },
      },
    ],
  },
];
export const subRouter = [];
